package com.easylinkin.linkappapi.airconditioner.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.IService;
import com.easylinkin.linkappapi.airconditioner.entity.AirconditionDevice;
import org.springframework.web.multipart.MultipartFile;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.util.List;
import java.util.Set;

public interface AirconditionDeviceService extends IService<AirconditionDevice> {


    void batchInsert(List<AirconditionDevice> list);

    IPage<AirconditionDevice> getPage(IPage<AirconditionDevice> page,AirconditionDevice airconditionDevice);

    /***
     * 批量,单个修改
     */
    void  updateDeviceFan(AirconditionDevice airconditionDevice);

    /***
     * 获取主机下所有设备
     * @param airconditionDevice
     * @return
     */
    List<AirconditionDevice> getHostLowerAirconditionDeviceAll(AirconditionDevice airconditionDevice);


    /***
     * 移除设备
     * @param airconditionDevice
     */
    void removeHostLowerAirconditionDeviceById(AirconditionDevice airconditionDevice);

    /***
     * 下载导入模板
     * @param request
     * @param response
     */
    void getImportTemplate(HttpServletRequest request, HttpServletResponse response);

    /**
     * 导入数据
     *
     * @param file xls文件
     */
    Set importData(MultipartFile file);

    AirconditionDevice getById(String deviceId);
}

